package main

import (
	"encoding/json"
	"fmt"
	"log"
)

func main() {
	blob := `{"str":"str","array":[1,2,3],"bool":true,"number":1.1,"object":{"str":"str","number":123}}`

	type DataType1 struct {
		Str    string
		Number int
	}

	type DataType struct {
		Str    string
		Array  []int
		Bool   bool
		Number float32
		Object DataType1
	}

	var data DataType

	data.Object.Str = `cctv`

	if err := json.Unmarshal([]byte(blob), &data); err != nil {
		log.Fatal(err)
	}

	fmt.Printf("Str:%s\n", data.Object.Str)
}
